package com.echat.business.home.service;


import com.baomidou.mybatisplus.service.IService;
import com.echat.business.home.model.SysUser;

/**
 * <p>
 * 服务类
 * </p>
 *
 * @author chentl123
 * @since 2019-05-28
 */
public interface ISysUserService extends IService<SysUser> {
    /**
     * 根据id 获取用户
     *
     * @param userId
     * @return
     */
    SysUser getUserById(Integer userId);

    /**
     * @return java.lang.String
     * @author chentl
     * @description 根据用户名获取用户密码
     * @date 2019/6/8 13:52
     * @params [userName]
     * @since JDK 1.7
     */
    String getPasswordByUserName(String userName);

    /**
     * @return com.echat.business.home.model.SysUser
     * @author chentl
     * @description 根据第三方用户id获取系统中关联的用户信息
     * @date 2019/8/3 0:08
     * @params [thirdId]
     * @since JDK 1.7
     */
    SysUser getUserByThirdId(Integer thirdId);

    /**
     * 校验用户名密码
     *
     * @param username
     * @param password
     * @return
     */
    SysUser userValid(String username, String password);

    /**
     * 根据用户名获取用户信息
     *
     * @param username
     * @return
     */
    SysUser getUserByName(String username);
}
